<%@ page contentType="text/html;charset=UTF-8" trimDirectiveWhitespaces="true"%>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<c:set var="extLibs" value="grid"/>
<sys:header title="福利发放管理" extLibs="${extLibs}" />
<div class="portlet box ${boxStyleColor}">
	<div class="portlet-title">
		<div class="caption"><i class="fa fa-coffee"></i> 采购统计</div>
		<div class="actions">
			<a href="#" class="btn btn-default btn-sm" id="btnSearch" title="查询"><i class="fa fa-search"></i> 查询</a>
		</div>
	</div>
	<div class="portlet-body list">
		<form:form id="searchForm" modelAttribute="malWelfareDis" action="${ctx}/mal/malWelfareDis/statisticsPage" method="post" class="breadcrumb form-inline hide"
				data-page-no="${page.pageNo}" data-page-size="${page.pageSize}" data-order-by="${page.orderBy}">
			<div class="form-group">
				<label class="control-label">节日：</label>
				<div class="input-inline">
					<form:select path="festivalId" multiple="false" cssClass="form-control" class="form-control  input-sm width-180" cssStyle="width:180px" onchange="">
						<option value=""> </option>
						<form:options items="${malFestivalWelfareList}"  itemLabel="festival" itemValue="id" htmlEscape="false"></form:options>
					</form:select>
				</div>
			</div>

			<div class="form-group">
				<label class="control-label">套餐：</label>
				<div class="input-inline">
					<form:select path="setMealId" multiple="false" cssClass="form-control" class="form-control  input-sm width-180" cssStyle="width:180px" onchange="">
						<option value=""> </option>
						<form:options items="${malSetMealList}"  itemLabel="name" itemValue="id" htmlEscape="false"></form:options>
					</form:select>
				</div>
			</div>

			<div class="form-group" style="margin-left:10px;"> 
				<input class="btn btn-primary btn-sm" type="submit" value="查询"/>&nbsp;
				<input class="btn default btn-sm" type="reset" value="重置"/>
			</div>
		</form:form>
		<table id="dataGrid"></table>
	    <div id="dataGridPage"></div>
	</div>
</div>
<sys:footer extLibs="${extLibs}" />
<script type="text/javascript">
	// 初始化DataGrid对象
	$("#dataGrid").dataGrid({
		
		searchForm: $("#searchForm"), // 数据来源表单
		tabPageId: '${param.tabPageId}',// 当前页签编号
		
		// 设置数据表格列
		columnModel: [
			{header:'节日标题', name:'festivalTitle', index:'a.festival_title', width:300, align:"left", frozen:true},
			{header:'套餐', name:'setMealName', index:'a.set_meal_name', width:200, align:"left"},
			{header:'会员数量', name:'memberNum', width:100, align:"left"},
			<%--{header:'操作', name:'actions', width:100, fixed:true, sortable:false, formatter: function(val, obj, row, act){--%>
				<%--var actions = [];//<shiro:hasPermission name="mal:malWelfareDis:edit">--%>
				<%--if (row.status == Global.STATUS_NORMAL){--%>
					<%--actions.push('<a href="${ctx}/mal/malWelfareDis/form?id='+row.id+'" class="btnList" title="编辑福利发放"><i class="fa fa-pencil"></i></a>&nbsp;');--%>
					<%--actions.push('<a href="${ctx}/mal/malWelfareDis/delete?id='+row.id+'" class="btnList" title="删除该福利发放" data-confirm="确认要删除该福利发放吗？"><i class="fa fa-trash-o"></i></a>&nbsp;');--%>
				<%--}//</shiro:hasPermission>--%>
				<%--return actions.join('');--%>
			<%--}}--%>
		],
		ajaxSuccess: function(data){ // 加载成功后执行方法
			
		}
	});
</script>